const { createProxyMiddleware }=require("http-proxy-middleware");
module.exports=(app)=>{ 
    app.use(createProxyMiddleware('/api', {
        target: 'http://localhost:3000',/*这里写自己的代理地址*/
        changeOrigin: true,//允许跨域
    }));
}